<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="/struts-tags" prefix="s"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script language="javascript" type="text/javascript"src="js/jquery-1.8.3.js"></script>
<script language="javascript" type="text/javascript"src="js/common.js"></script>
<title>Modify WorkRequest</title>
<link href="css/table.css" rel="stylesheet" type="text/css" />
<link href="css/base.css" rel="stylesheet" type="text/css" />
<script language="JavaScript" src="<%=basePath %>js/jquery-calendar.js"></script>
<link href="css/jquery-calendar.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
//<![CDATA[
	$(document).ready(function (){
		$("#userProposedDate,#sdate,#smStartDate,#dueDate,#modifyEndDate,#proposedDate,#qtransDate,#etransDate,#ptransDate,#endDate").calendar({
			//初始化
			dateFormat: 'YMD/',     //日期格式
			timeSeparators:''       //时分设置
		});
	});
//]]>
function check(event) {
	if((event.keyCode<48 || event.keyCode>57)||(event.keyCode>=96&&event.keyCode<=105) && event.keyCode!=46 || /\.\%\d\d$/.test(event)){
        event.returnValue=false;
	}
}
function add() {
	var idArray = new Array("basewrNo","type","wrName","dueDate","category","cdcReview",
							"submittedKey","inChargeCdcKey");
	var checkflg=true;
		checkflg=checkEmpty(idArray,checkflg);
		if(checkflg){
			var r = confirm("<s:text name='MSG00003'/>");
			if (r) {
				document.forms[0].action = "menu_workReques";
				document.forms[0].submit();
			}
		}
}
function back() {
	document.forms[0].action = "look_wrDetail";
	document.forms[0].submit();
}
</script>
</head>
<body>
	<div id="container">
	<div id="header" style="padding-left:50px;">
	<h1><s:text name="CMS00003_LABEL_DETAIL"/></h1>
	</div>
	<center>
	<div id="message" align="left" style="padding-left:280px;">
		<span style="color:red;">(*)</span>必須情報
	</div>
	<div id="contents">
	<s:form theme="simple" validate="true" onsubmit="return false">
	<table class="table" style="width:700px;">
		<tr>
			<td style="padding-right: 50px;">
			<table class="table">
				<tr >
					<td class="tdString" id="base_wrNo"><s:text name="CMS00003_LABLE_BASEWRNO"/><span style="color:red;">(*)</span></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.basewrNo" maxlength="6"
						id="basewrNo" cssStyle="width: 94px; float:left;" />例：C0xxxx</td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_TODOLIST"/></td>
					<td><s:select list="workRequestViewBean.selectListBean.todoList"
						name="workRequestViewBean.workRequestDetail.todo" id="todo"
						listKey="key" listValue="name" headerValue=""
						headerKey="0" cssStyle="width: 100px; float:left;"></s:select></td>
				</tr>
				<tr>
					<td class="tdString" id="requestType"><s:text name="CMS00003_LABLE_REQUESTKEY"/><span style="color:red;">(*)</span></td>
					<td><s:select list="workRequestViewBean.selectListBean.typeList"
						name="workRequestViewBean.workRequestDetail.type" id="type"
						listKey="key" listValue="name" headerValue=""
						headerKey="0" cssStyle="width: 100px; float:left;">
					</s:select></td>
				</tr>
				<tr>
					<td class="tdString" id="wr_name"><s:text name="CMS00002_LABEL_WRNAME"/><span style="color:red;">(*)</span></td>
					<td><s:textarea rows="1" cols="50"name="workRequestViewBean.workRequestDetail.wrName"
					id="wrName"
						cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_STATUS"/></td>
					<td><s:select list="workRequestViewBean.selectListBean.statusList"
						name="workRequestViewBean.workRequestDetail.status" id="status"
						listKey="key" listValue="name" headerValue=""
						headerKey="0" cssStyle="width: 100px; float:left;">
					</s:select></td>
				</tr>
				<tr>
					<td class="tdString" id="inchargekey"><s:text name="CMS00003_LABLE_RESOURCESNAME"/><span style="color:red;">(*)</span></td>
					<td><s:select list="workRequestViewBean.selectListBean.allUserName" 
						name = "workRequestViewBean.workRequestDetail.inChargeCdcKey" 
						id="inChargeCdcKey"
						listKey="key" listValue="name" headerValue="" headerKey="0" 
						cssStyle="width: 100px; float:left;"/></td>
				</tr>
				<tr>
					<td class="tdString" id="team"><s:text name ="CMS00003_LABEL_TEAM"/></td>
					<td>
						<s:select
							list="workRequestViewBean.selectListBean.teamName" 
							name="workRequestViewBean.workRequestDetail.teamNameId" 
							listKey="key" listValue="name" headerValue="All" headerKey="0"
							cssStyle="width: 100px;float:left;" id="teamName">
						</s:select>
					</td>
				</tr>
				<tr>
					<td class="tdString" id="cdc_Review"><s:text name="CMS00003_LABLE_CDCREVIEW"/><span style="color:red;">(*)</span></td>
					<td><s:select list="workRequestViewBean.selectListBean.cdcReviewer"
						name="workRequestViewBean.workRequestDetail.cdcReview" id="cdcReview"
						listKey="key" listValue="name" headerValue=""
						headerKey="0" cssStyle="width: 100px; float:left;">
					</s:select></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_CDCWRID"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.cdcWrid" id="cdcWrid"
						maxlength="6"
						cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_SMHOUR"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.smHour" id="smHour"
						onkeyup="value=value.replace(/[^\d]/g,'')"
						cssStyle="width: 94px; float:left;" cssClass="tdNumber"/></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_TRANSHOUR"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.transHour"
						id="transHour" onkeyup="value=value.replace(/[^\d]/g,'')"
						cssStyle="width: 94px; float:left;" cssClass="tdNumber"/></td>
				</tr>
				<tr>
					<td class="tdString" id="due_Date"><s:text name="CMS00003_LABLE_DUEDATE"/><span style="color:red;">(*)</span></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.dueDate" id="dueDate"
						cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_ESTIMATEDHOUR"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.estimatedHour"
						id="estimatedHour" onkeyup="value=value.replace(/[^\d]/g,'')"
						cssStyle="width: 94px; float:left;" cssClass="tdNumber"/></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_ACTUALHOUR"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.actualHour"
						id="actualHour" onkeyup="value=value.replace(/[^\d]/g,'')"
						cssStyle="width: 94px; float:left;" cssClass="tdNumber"/></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_ACHIEVEMENT"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.percentage"
						id="percentage" onkeyup="value=value.replace(/[^\d\%]/g,'')"
					    cssStyle="width: 94px; float:left;" cssClass="tdNumber"/></td>
				</tr>
				<tr>
					<td colspan="2" class="tdString"><s:text name="CMS00003_LABLE_EXPLAIN"/></td>
				</tr>
				<tr>
					<td colspan="2" align="left"><s:textarea rows="7" cols="25"
						name="workRequestViewBean.workRequestDetail.description"
						cssStyle=" "></s:textarea></td>
				</tr>
			</table>
			</td>
			<td >
			<table class="table">
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_INVESTIGATION"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.sdate" id="sdate" 
						cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_MODIFYENDDATE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.modifyEndDate" 
						id="modifyEndDate" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_PRIORITY"/></td>
					<td><s:select list="workRequestViewBean.selectListBean.priorityList"
						name="workRequestViewBean.workRequestDetail.priority"
						id="priority" listKey="key" listValue="name"
						headerValue="" headerKey="0" cssStyle="width: 100px; float:left;">
					</s:select></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_SMSNO"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.smsNo" id="smsNo"
						cssStyle="width: 94px; float:left;" maxlength="10"/></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_APPLICANT"/><span style="color:red;">(*)</span></td>
					<td>
					<s:select list="workRequestViewBean.selectListBean.tokyoReviewer"
						name="workRequestViewBean.workRequestDetail.submittedKey" id="submittedKey"
						listKey="key" listValue="name" headerValue=""
						headerKey="0" cssStyle="width: 100px; float:left;">
					</s:select>
					</td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_USERCOMPLETE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.userProposedDate"
						id="userProposedDate"
						cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString" id="category_Type"><s:text name="CMS00003_LABLE_CATEGORY"/><span style="color:red;">(*)</span></td>
					<td><s:select list="workRequestViewBean.selectListBean.categoryList"
						name="workRequestViewBean.workRequestDetail.category"
						id="category" listKey="key" listValue="name"
						headerValue="" headerKey="0" cssStyle="width: 100px; float:left;"></s:select>
					</td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_LEVEL"/></td>
					<td><s:select list="workRequestViewBean.selectListBean.levelList"
						name="workRequestViewBean.workRequestDetail.level" id="level"
						listKey="key" listValue="name" headerValue=""
						headerKey="0" cssStyle="width: 100px; float:left;">
					</s:select></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_SMSTTARTDATE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.smStartDate"
						id="smStartDate" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_PROPOSED"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.proposedDate"
						id="proposedDate" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_QTRANDATE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.qtransDate"
						id="qtransDate" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_ETRANDATE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.etransDate"
						id="etransDate" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_PTRANDATE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.ptransDate"
						id="ptransDate" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_TRANSFERRED"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.allTransFlag" maxlength="2"
						id="allTransFlag" cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td class="tdString"><s:text name="CMS00003_LABLE_ENDDATE"/></td>
					<td><s:textfield
						name="workRequestViewBean.workRequestDetail.endDate"
						id="endDate"
					    cssStyle="width: 94px; float:left;" /></td>
				</tr>
				<tr>
					<td colspan="2" class="tdString"><s:text name="CMS00003_LABLE_REMARKS"/></td>
				</tr>
				<tr>
					<td colspan="2" align="left"><s:textarea rows="8" cols="25"
						name="workRequestViewBean.workRequestDetail.note"
						cssStyle=" "></s:textarea></td>
				</tr>
			</table>
			</td>
		</tr>
		<tr>
			<td align="right"></td>
			<td align="right"><s:submit value="%{getText('COMMON_BUTTON_SUBMIT')}" cssClass="ButtonCss" onclick="add();"/>
				<s:submit name="Back" value="%{getText('COMMON_BUTTON_BACK')}" cssClass="ButtonCss" onclick="back();"/></td>
		</tr>
	</table>
	<s:hidden name="workRequestViewBean.wrId"></s:hidden>
		<s:hidden name="workRequestViewBean.workRequestDetail.wrId"></s:hidden>
	</s:form>
	</div>
</center>
	<div id="footer">Copyright www.accenture.com</div>
	</div>
</body>
</html>
